/**
 * Copyright 2020 OPSLI 快速开发平台 https://www.opsli.com
 * <p>
 * Licensed under the Apache License, Version 2.0 (the "License"); you may not
 * use this file except in compliance with the License. You may obtain a copy of
 * the License at
 * <p>
 * http://www.apache.org/licenses/LICENSE-2.0
 * <p>
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
 * WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
 * License for the specific language governing permissions and limitations under
 * the License.
 */
package org.opsli.api.wrapper.customer.record;

import com.alibaba.excel.annotation.ExcelProperty;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.opsli.api.base.warpper.ApiWrapper;
import org.opsli.common.annotation.validator.Validator;
import org.opsli.common.annotation.validator.ValidatorLenMax;
import org.opsli.common.enums.ValidatorType;
import org.opsli.plugins.excel.annotation.ExcelInfo;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
 * BrokerRecord Model
 *
 * @author guagua
 * @date 2025-06-12 13:51:39
 */
@Data
@EqualsAndHashCode(callSuper = false)
public class CustomerRecordModel extends ApiWrapper {

    /**
     * 类型
     */
    @ApiModelProperty(value = "类型")
    @ExcelProperty(value = "类型", order = 0)
    @ExcelInfo(dictType = "broker_record_type")
    @Validator({
            ValidatorType.IS_NOT_NULL,
            ValidatorType.IS_INTEGER
    })
    @ValidatorLenMax(2)
    private String type;

    /**
     * 描述
     */
    @ApiModelProperty(value = "描述")
    @ExcelProperty(value = "描述", order = 1)
    @ExcelInfo
    private String description;

    /**
     * 详情
     */
    @ApiModelProperty(value = "详情")
    @ExcelProperty(value = "详情", order = 2)
    @ExcelInfo
    private String details;

    /**
     * 附件
     */
    @ApiModelProperty(value = "附件")
    @ExcelProperty(value = "附件", order = 3)
    @ExcelInfo
    private String attachments;

    /**
     * 联系方式
     */
    @ApiModelProperty(value = "联系方式")
    @ExcelProperty(value = "联系方式", order = 4)
    @ExcelInfo(dictType = "communication_type")
    @ValidatorLenMax(1)
    private String communicationType;

    /**
     * 联系时长
     */
    @ApiModelProperty(value = "联系时长")
    @ExcelProperty(value = "联系时长", order = 5)
    @ExcelInfo
    @ValidatorLenMax(5)
    private Integer duration;

    /**
     * customerId
     */
    @ApiModelProperty(value = "customerId")
    @ExcelProperty(value = "customerId", order = 6)
    @ExcelInfo
    @Validator({
            ValidatorType.IS_NOT_NULL
    })
    @ValidatorLenMax(22)
    private String customerId;

    /**
     * 提醒时间
     */
    @ApiModelProperty(value = "提醒时间")
    @ExcelProperty(value = "提醒时间", order = 7)
    @ExcelInfo
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd'T'HH:mm")
    @DateTimeFormat(pattern = "yyyy-MM-dd'T'HH:mm")
    private Date reminderTime;

    /**
     * 提醒人
     */
    @ApiModelProperty(value = "提醒人")
    @ExcelProperty(value = "提醒人", order = 8)
    @ExcelInfo
    @ValidatorLenMax(22)
    private String assignedTo;

    /**
     * 联系时间
     */
    @ApiModelProperty(value = "联系时间")
    @ExcelProperty(value = "联系时间", order = 9)
    @ExcelInfo
    @JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date communicationTime;

    /**
     * 父级主键集合
     */
    @ApiModelProperty(value = "父级主键集合")
    @ExcelProperty(value = "父级主键集合", order = 11)
    @ExcelInfo
    @ValidatorLenMax(500)
    private String orgIds;


}